﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;

namespace BLL.DTO.HelperDTO
{
    public class RegisterDTO
    {
        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "rutRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "rutLabel")]
        public string rut_Persona { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "nameRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "nameLabel")]
        public string nombres_Persona { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "lastName1Required")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "lastName1Label")]
        public string apellidoPaterno_Persona { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "lastName2Required")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "lastName2Label")]
        public string apellidoMaterno_Persona { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "birthdayRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "birthdayLabel")]
        public DateTime fechaNacimiento_Persona { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "genderRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "genderLabel")]
        public int codigoGenero_Genero { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "comunaRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "comunaLabel")]
        public int codigoComuna_Comuna { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "ciudadRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "ciudadLabel")]
        public int codigoCiudad_Ciudad { get; set; }

        [Display(ResourceType = typeof(Resources.Business.Register), Name = "regionLabel")]
        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "regionRequired")]
        public int codigoRegion_Region { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "passwordRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "passwordLabel")]
        public string password_Usuario { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "preguntaRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "preguntaLabel")]
        public string codigoPregunta_PreguntaSecreta { get; set; }

        [Required(ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "respuestaRequired")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "respuestaLabel")]
        public string respuesta_Usuario { get; set; }

        [Display(ResourceType = typeof(Resources.Business.Register), Name = "phoneLabel")]
        public int? telefono_Persona { get; set; }

        [Display(ResourceType = typeof(Resources.Business.Register), Name = "cellphoneLabel")]
        public int? celular_Persona { get; set; }

        [RegularExpression("^[a-zA-Z0-9_\\.-]+@([a-zA-Z0-9-]+\\.)+[a-zA-Z]{2,6}$", ErrorMessageResourceType = typeof(Resources.Business.Register), ErrorMessageResourceName = "mailWrong")]
        [Display(ResourceType = typeof(Resources.Business.Register), Name = "mailLabel")]
        public string correo_Persona { get; set; }
    }
}
